package edu.xcdq;

import java.util.Scanner;

public class Demo02 {
    public static void main(String[] args) {

        Scanner  scanner =  new Scanner(System.in); //定义一个键盘扫描器
        System.out.println("请输入计算机基础的成绩：");
        int  score1 = scanner.nextInt();

        System.out.println("请输入Java的成绩：");
        int  score2 = scanner.nextInt();

        System.out.println("请输入mysql的成绩：");
        int  score3 = scanner.nextInt();

        int different = score1-score2;
        System.out.println("计算机基础与Java之间的成绩差："+different);

        double  avg =(score1+score2+ score3)/3.0;
        System.out.println("平均成绩为："+avg);

    }
}
